package com.example.demo.service;

import com.example.demo.config.RedisException;
import com.example.demo.entity.Talk;

/**
 * @author Code Farmer
 * @date 2020/4/22 15:55
 */
public interface LikeService {

    /**
     * 点赞或取消点赞
     */
    boolean likeAndCancelLike(Talk talk) throws RedisException;

    /**
     * 获取赞数
     */
    long getLikeCount(Talk talk) throws RedisException;

    /**
     *  是否点赞
     */
    boolean isLike(Talk talk) throws RedisException;

}
